package test;

import java.util.ArrayList;
import java.util.HashMap;

import myAsm.MyVarInsnNode;

public class Result {
	
	private ArrayList<Integer> methodTested;
	private HashMap<Integer,ArrayList<methodResult>> methodResults;

	public Result(){
		this.methodTested = new ArrayList<Integer>();
		this.methodResults = new HashMap<Integer,ArrayList<methodResult>>();
	}
	
	public Result(ArrayList<Integer> methodTested) {
		this.methodTested=methodTested;
		this.methodResults = new HashMap<Integer,ArrayList<methodResult>>();
	}
	
	
	public HashMap<Integer, ArrayList<methodResult>> getMethodResults() {
		return methodResults;
	}

	public void setMethodResults(HashMap<Integer, ArrayList<methodResult>> methodResults) {
		this.methodResults = methodResults;
	}

	
	public ArrayList<Integer> getMethodTested() {
		return this.methodTested;
	}

	public void setMethodTested(ArrayList<Integer> methodToTest) {
		this.methodTested = methodToTest;
	}

	

	public void addMR(methodResult mR) {
		if (this.methodResults.containsKey(mR.getId())){
			this.methodResults.get(mR.getId()).add(mR);
		}
		else {
			this.methodResults.put(mR.getId(),new ArrayList<methodResult>());
			this.methodResults.get(mR.getId()).add(mR);
		}
	}
	
}
